//
//  BaseService.h
//  NewsReader
//
//  Created by blacksun on 11-2-16.
//  Copyright 2011 __MyCompanyName__. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "Request.h"
#import "NewsReaderAppDelegate.h"

@protocol ServiceDelegate

- (void)onServiceSuccess:(id)aResult command:(int)aCommand identifier:(id)identifier; 
- (void)onServiceFailure:(int)aStatudCode command:(int)aCommand identifier:(id)identifier;
@end


@interface BaseService : NSObject<RequestDelegate> {
	NewsReaderAppDelegate *appDelegate;
	id<ServiceDelegate> delegate;
	NSMutableDictionary *activeRequest;

}
@property (nonatomic, assign) NewsReaderAppDelegate *appDelegate;
@property (nonatomic, retain) id delegate;
@property (nonatomic, retain) NSMutableDictionary *activeRequest;

-(id)initWithDelegate:(id)aDelegate;

@end
